﻿using DoNet.ApiHttpClient.WechatMch;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;

namespace DoNet.WechatPay
{
    /// <summary>
    /// 微信支付请求基类
    /// </summary>
    public class WechatMchBase
    {
        /// <summary>
        /// 日志
        /// </summary>
        public ILogger logger;
        /// <summary>
        /// 微信公众平台请求服务
        /// </summary>
        public WechatMchService? wechatMchService;
        /// <summary>
        /// 微信公众平台请求
        /// </summary>
        /// <param name="_logger"></param>
        /// <param name="provider"></param>
        public WechatMchBase(ILogger _logger, IServiceProvider provider)
        {
            logger = _logger;
            wechatMchService = provider.GetService<WechatMchService>();
        }
    }
}
